﻿<UserControl
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             xmlns:igCA="http://infragistics.com/Chart" x:Class="Views.ViewDashboardDefinition" 
             xmlns:local="clr-namespace:OMANE.Modules.Indicateurs"
             xmlns:localc="clr-namespace:OMANE.Modules.Indicateurs.Views.Converters"
             mc:Ignorable="d" 
             d:DesignHeight="300" d:DesignWidth="300">
	
	<UserControl.Resources>
        <localc:DefintionToLayoutConverter x:Key="lconv" />
		<Style TargetType="{x:Type GridSplitter}">
			<Setter Property="HorizontalAlignment" Value="Stretch"/>
			<Setter Property="VerticalAlignment" Value="Stretch"/>
			<Setter Property="Background" Value="Black"/>
			
		</Style>
		<Style x:Key="ZoneToggleButton" TargetType="{x:Type ToggleButton}">
			<Setter Property="Template" >
				<Setter.Value>
					<ControlTemplate TargetType="{x:Type ToggleButton}">
						<Border x:Name="border" BorderThickness="{Binding GraphDefinition.BorderSize}" CornerRadius="{Binding GraphDefinition.CornerRadius}">
							<Border.Background>
								<SolidColorBrush Color="{Binding GraphDefinition.BackColor}" />
							</Border.Background>
							<Border.BorderBrush>
								<SolidColorBrush Color="{Binding GraphDefinition.BorderColor}" />
							</Border.BorderBrush>
							<ContentControl Content="{Binding GraphDefinition.DetailInstance}" />														
						</Border>
					</ControlTemplate>
				</Setter.Value>
			</Setter>
			<Setter Property="BorderThickness" Value="5"/>
			<Setter Property="IsChecked" Value="{Binding Selected}"/>
			<Setter Property="IsThreeState" Value="False"/>
			<Setter Property="Command" Value="{Binding Mode=OneWay, Path=EditCommand}"/>
            <Setter Property="Width" Value="{Binding GraphDefinition, Converter={StaticResource lconv}, ConverterParameter=0}" />
            <Setter Property="Height" Value="{Binding GraphDefinition, Converter={StaticResource lconv}, ConverterParameter=1}" />
            <Setter Property="Margin" Value="{Binding GraphDefinition, Converter={StaticResource lconv}, ConverterParameter=6}" />
            <Setter Property="HorizontalAlignment" Value="{Binding GraphDefinition, Converter={StaticResource lconv}, ConverterParameter=7}"/>
            <Setter Property="VerticalAlignment" Value="{Binding GraphDefinition, Converter={StaticResource lconv}, ConverterParameter=8}"/>
        </Style>
		<Style x:Key="GraphModelStyle" TargetType="{x:Type Button}">
			<Setter Property="Template">
				<Setter.Value>
					<ControlTemplate TargetType="{x:Type Button}">
						<Grid>
							<igCA:XamChart />
					    </Grid>
						<ControlTemplate.Triggers>
							<Trigger Property="IsFocused" Value="True"/>
							<Trigger Property="IsDefaulted" Value="True"/>
							<Trigger Property="IsMouseOver" Value="True"/>
							<Trigger Property="IsPressed" Value="True"/>
							<Trigger Property="IsEnabled" Value="False"/>
						</ControlTemplate.Triggers>
					</ControlTemplate>
				</Setter.Value>
			</Setter>
		</Style>
	</UserControl.Resources>
    <Grid>
    	<Grid x:Name="DefZone">
    	    	</Grid>
            
    </Grid>
</UserControl>
